FormBuilder.registerWidgets 'question',
  view: """
<div class='form-group'>
<label >评分</label>
<div >
<input id='<%=rf.cid %>' field_type='question' type="text" />
<script type='application/javascript'>

  $("#<%=rf.cid %>").slider({
      value:<%=rf.get("defaultvalue")%>,
      step: 1,
      min: 0,
      max: <%=rf.get("max")%>,
      ticks: [<%=rf.get("ticks") %>],
      ticks_labels: [<%=rf.get("ticks") %>],
      ticks_snap_bounds: 30
  }).on('change', function(event) {
    $('#hidden-<%=rf.cid %>').val(event.value.newValue).change();
   });
</script>
<input id='hidden-<%=rf.cid %>' type='hidden' class='slider-value form-control'>
 </div>
</div>
<div class='form-group'>
<div >
<table class="table table-bordered">
<% _.each(rf.get("table"), function(item,index){ %>
  <tr >
    <td style="width:50px">
        <span class="label label-danger"><%=item.score%></span>
    </td>
    <td><%=item.content%></td>
  </tr>
<% });%>
</table>
</div>
</div>
<div class="form-group">
<label for="">评论</label>
<textarea class="form-control" rows="3" rv-value="model:comment"></textarea>
</div>
"""

